<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Common API 接口文档</title>
    <style>
        body {
            font-family: Arial, sans-serif;
            line-height: 1.6;
            margin: 0;
            padding: 20px;
            color: #333;
        }
        h1 {
            color: #2c3e50;
            border-bottom: 2px solid #3498db;
            padding-bottom: 10px;
        }
        .endpoint {
            background-color: #f9f9f9;
            border-left: 4px solid #3498db;
            padding: 15px;
            margin-bottom: 20px;
            border-radius: 0 4px 4px 0;
        }
        .method {
            display: inline-block;
            padding: 3px 10px;
            background-color: #3498db;
            color: white;
            border-radius: 3px;
            font-weight: bold;
            margin-right: 10px;
        }
        .url {
            font-family: monospace;
            font-size: 16px;
        }
        table {
            width: 100%;
            border-collapse: collapse;
            margin: 15px 0;
        }
        th, td {
            border: 1px solid #ddd;
            padding: 8px;
            text-align: left;
        }
        th {
            background-color: #f2f2f2;
        }
        .example {
            background-color: #f5f5f5;
            padding: 10px;
            border-radius: 4px;
            font-family: monospace;
            white-space: pre-wrap;
        }
    </style>
</head>
<body>
<h1>Common API 接口文档</h1>

<div class="endpoint">
    <h2><span class="method">POST</span> <span class="url">http://36.2.14.202/coflxl/api/common/search/{key}</span></h2>
    <p>根据key执行搜索查询，返回列表数据</p>

    <h3>请求参数</h3>
    <table>
        <tr>
            <th>参数位置</th>
            <th>参数名称</th>
            <th>类型</th>
            <th>必填</th>
            <th>描述</th>
        </tr>
        <tr>
            <td>路径参数</td>
            <td>key</td>
            <td>String</td>
            <td>是</td>
            <td>查询标识key</td>
        </tr>
        <tr>
            <td>请求体</td>
            <td>paramMap</td>
            <td>Map</td>
            <td>是</td>
            <td>查询参数键值对</td>
        </tr>
    </table>

    <h3>响应示例</h3>
    <div class="example">
        {
        "code": 200,
        "message": "success",
        "data": [
        {
        "id": 1,
        "name": "示例数据1"
        },
        {
        "id": 2,
        "name": "示例数据2"
        }
        ]
        }
    </div>
</div>

<div class="endpoint">
    <h2><span class="method">POST</span> <span class="url">http://36.2.14.202/coflxl/api/common/searchByOne/{key}</span></h2>
    <p>根据key执行搜索查询，返回单条数据</p>

    <h3>请求参数</h3>
    <table>
        <tr>
            <th>参数位置</th>
            <th>参数名称</th>
            <th>类型</th>
            <th>必填</th>
            <th>描述</th>
        </tr>
        <tr>
            <td>路径参数</td>
            <td>key</td>
            <td>String</td>
            <td>是</td>
            <td>查询标识key</td>
        </tr>
        <tr>
            <td>请求体</td>
            <td>paramMap</td>
            <td>Map</td>
            <td>是</td>
            <td>查询参数键值对</td>
        </tr>
    </table>

    <h3>响应示例</h3>
    <div class="example">
        {
        "code": 200,
        "message": "success",
        "data": {
        "id": 1,
        "name": "示例数据",
        "value": "示例值"
        }
        }
    </div>
</div>

<div class="endpoint">
    <h2><span class="method">POST</span> <span class="url">http://36.2.14.202/coflxl/api/common/searchPage/{key}</span></h2>
    <p>根据key执行分页搜索查询</p>

    <h3>请求参数</h3>
    <table>
        <tr>
            <th>参数位置</th>
            <th>参数名称</th>
            <th>类型</th>
            <th>必填</th>
            <th>描述</th>
        </tr>
        <tr>
            <td>路径参数</td>
            <td>key</td>
            <td>String</td>
            <td>是</td>
            <td>查询标识key</td>
        </tr>
        <tr>
            <td>请求体</td>
            <td>pageDto</td>
            <td>SysCommonSearchPageDTO</td>
            <td>是</td>
            <td>分页查询参数</td>
        </tr>
    </table>

    <h4>SysCommonSearchPageDTO 结构</h4>
    <div class="example">
        {
        "pageNo": 1,       // 当前页码
        "pageSize": 10,         // 每页大小
        "map": {         // 查询参数
        "name": "示例"
        }
        }
    </div>

    <h3>响应示例</h3>
    <div class="example">
        {
        "code": 200,
        "message": "success",
        "data": {
        "records": [
        {
        "id": 1,
        "name": "示例数据1"
        },
        {
        "id": 2,
        "name": "示例数据2"
        }
        ],
        "total": 2,
        "size": 10,
        "current": 1,
        "pages": 1
        }
        }
    </div>
</div>

</body>
</html>